﻿using System.Collections.Generic;
using System.Configuration;
using System.Linq;

namespace TSMonitor.Core
{
	public class ServerInfoRepository
	{
		 public List<ServerInfo> GetRegisteredServers()
		 {
			 return ConfigurationManager
				 .AppSettings["registeredServers"]
				 .Split(';')
				 .Where(s=> !string.IsNullOrEmpty(s))
				 .Select(s => new ServerInfo { TargetServer = s })
				 .ToList();
		 }
	}
}